package com.mybatis_puls.demo.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import java.util.Date;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableLogic;
import java.io.Serializable;

import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;

/**
 * <p>
 * 
 * </p>
 *
 * @author 小🌤
 * @since 2020-12-21
 */
@Data
@EqualsAndHashCode(callSuper = false)
@ApiModel(value="OrderS对象", description="")
public class OrderS  implements Serializable {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(value = "主键")
    @TableId(value = "uuid", type = IdType.ID_WORKER)
    private String uuid;

    @ApiModelProperty(value = "发布订单的用户id")
    private Integer userId;

    @ApiModelProperty(value = "帮助人id")
    private Integer helpId;

    @ApiModelProperty(value = "赏金")
    private Double money;

    @ApiModelProperty(value = "帮助标题")
    private String title;

    @ApiModelProperty(value = "帮助详情id")
    private Integer detailId;
    @JsonFormat(pattern = "yyyy年/MM月/dd天|HH时:mm分:ss秒")  //自定义日期转换
    @ApiModelProperty(value = "帮助时间")
    private Date time;

    @ApiModelProperty(value = "目的地:地址")
    private Integer addressId;

    @ApiModelProperty(value = "逻辑删除")
    @TableLogic
    private Integer deleted;

    //status ==0?'需要帮助':status ==1 '已帮助' 帮助完成==2 status ==3?'待付款' status ==4?"已完成" status==5
    @ApiModelProperty(value = "状态码")
    private Integer status;

    @ApiModelProperty(value = "学校id")
    private Integer schoolId;

    @TableField(exist = false) // 注明非数据库字段属性
    private User user;
    @TableField(exist = false) // 注明非数据库字段属性
    private Address address;
    @TableField(exist = false) // 注明非数据库字段属性
    private User helpUser;
    @TableField(exist = false) // 注明非数据库字段属性
    private FileS fileS;
}
